/*
*    Phantom v2.0 GUI Automation Software
*    Copyright (C) 2009  John C. Van Arsdall (john@phantomtest.com)
*
*    This program is free software; you can redistribute it and/or modify
*    it under the terms of the GNU General Public License as published by
*    the Free Software Foundation; either version 2 of the License, or
*    (at your option) any later version.
*
*    This program is distributed in the hope that it will be useful,
*    but WITHOUT ANY WARRANTY; without even the implied warranty of
*    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
*    GNU General Public License for more details.
*
*    You should have received a copy of the GNU General Public License along
*    with this program; if not, write to the Free Software Foundation, Inc.,
*    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*
*/
// Conditional.h: interface for the CConditional class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_CONDITIONAL_H__8FF99FBC_FCCB_49C4_B5B7_90462D13F2A6__INCLUDED_)
#define AFX_CONDITIONAL_H__8FF99FBC_FCCB_49C4_B5B7_90462D13F2A6__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "ssi_defines.h"

// These are the integer values representing a flow
#define COND_IF         1 
#define COND_WHILE      2
#define COND_FOR        4
#define COND_SWITCH     8
#define COND_ELSE       16
#define COND_ELSE_IF    17
#define COND_ELSE_WHILE 18
#define COND_ELSE_FOR   20
#define COND_TRY        24
#define COND_CATCH      25

// These define the opening and closing of a flow section
#define FLOW_BRACES         "{}"
#define FLOW_CLOSE_BRACE    "}"
#define FLOW_OPEN_BRACE     "{"

// These define the acceptable string versions of flow types
#define FLOW_IF             "if"
#define FLOW_ELSE_IF        "else if"
#define FLOW_ELSE           "else"
#define FLOW_FOR            "for"
#define FLOW_ELSE_FOR       "else for"
#define FLOW_WHILE          "while"
#define FLOW_ELSE_WHILE     "else while"
#define FLOW_SWITCH         "switch"
#define FLOW_TRY            "try"
#define FLOW_CATCH          "catch"

// This defines the delimeters acceptable to parse away a flow type
#define FLOW_SEPARATORS     "({ \n"

#define DO_NOT_RUN  -1

class SSI_SCRIPTDLL_API CConditional  
{
public:
	SSI_CHAR GetType();
	void SetType(SSI_CHAR inType);
	CConditional();
	virtual ~CConditional();
private:
  SSI_CHAR Type;
  SSI_BOOL bStatus;
};

#endif // !defined(AFX_CONDITIONAL_H__8FF99FBC_FCCB_49C4_B5B7_90462D13F2A6__INCLUDED_)



